Skip to content

Conversation

steel97
Copy link

@steel97 steel97 commented Jan 21, 2025

Latest version of extension will throw error shown below, if package published with:

npx gulp 'vsix:release:neutral'

screenshot

Reason is that neutral build doesn't contains TargetPlatform in vsixmanifest, which is required here:

const contents = await readFile(vsixManifestFile, 'utf-8');
const targetPlatformMatch = /TargetPlatform="(.*)"/.exec(contents);
if (!targetPlatformMatch) {
throw new Error(`Could not find extension target platform in ${vsixManifestFile}`);
}

Suggested solution is to return undefined instead of throwing error, in that case proccess.arch will be used:

const extensionArchitecture = (await this.getArchitectureFromTargetPlatform()) ?? process.arch;

Tested on: VSCodium 1.96.4, windows 11

Upd: also tested on macos (arm), same VSCodium version

@muhammadsammy muhammadsammy merged commit 0782dd6 into muhammadsammy:master Jan 27, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants